testuite/gsk: Add common_cflags to build
authorTimm Bäder <mail@baedert.org>
Fri, 6 Mar 2020 17:11:46 +0000 (18:11 +0100)
committerTimm Bäder <mail@baedert.org>
Fri, 6 Mar 2020 17:22:01 +0000 (18:22 +0100)
And fix all the warnings and errors.

testsuite/gsk/meson.build
testsuite/gsk/transform.c

index 2b53f219e55e0d5cd0bfd28687a8df078c29a752..8c4706f67e0d2f095450ae2566948f14d4b7fd64 100644 (file)
@@ -197,7 +197,7 @@ foreach t : tests
   test_extra_ldflags = t.get(3, [])
 
   test_exe = executable(test_name, test_srcs,
-    c_args : test_cargs + test_extra_cargs,
+    c_args : test_cargs + test_extra_cargs + common_cflags,
     link_args : test_extra_ldflags,
     dependencies : libgtk_dep,
     install: get_option('install-tests'),
index b90e4f4bc070db6681ed1afcdda8dda92e0dd1f0..6439952c3e378037ad0e7c844626b1f2ea8b48ff 100644 (file)
@@ -190,16 +190,16 @@ check_conversions (GskTransform         *transform,
                                   &f[4 * 3 + 0], &f[4 * 3 + 1]);
       graphene_matrix_init_from_float (&test, f);
       graphene_assert_fuzzy_matrix_equal (&matrix, &test, EPSILON);
-      /* fallthrough */
 
+      G_GNUC_FALLTHROUGH;
     case GSK_TRANSFORM_CATEGORY_2D_AFFINE:
       gsk_transform_to_affine (transform,
                                &f[4 * 0 + 0], &f[4 * 1 + 1],
                                &f[4 * 3 + 0], &f[4 * 3 + 1]);
       graphene_matrix_init_from_float (&test, f);
       graphene_assert_fuzzy_matrix_equal (&matrix, &test, EPSILON);
-      /* fallthrough */
 
+      G_GNUC_FALLTHROUGH;
     case GSK_TRANSFORM_CATEGORY_2D:
       gsk_transform_to_2d (transform,
                            &f[4 * 0 + 0], &f[4 * 0 + 1],
@@ -208,6 +208,9 @@ check_conversions (GskTransform         *transform,
       graphene_matrix_init_from_float (&test, f);
       graphene_assert_fuzzy_matrix_equal (&matrix, &test, EPSILON);
       break;
+
+    default:
+      g_assert_not_reached ();
    }
 }